import React from 'react';

export default class MyProgress extends React.Component<any, any>{
    render() {
        const { datas, colors, allStatusMap, statusList } = this.props;
        return <div style={{ backgroundColor: '#e2e2e2', height: '4px', marginTop: '12px', borderRadius: '2px' }}>
            {
                datas.map((element, index) => {
                    let style: any = { backgroundColor: colors[index], height: '4px', width: element + '%', float: 'left' };
                    style['borderRadius'] = '2px';
                    return <div title={allStatusMap[statusList[index]]} style={style}></div>
                })
            }
        </div>
    }
}